﻿<!DOCTYPE html>
<?php 
    function chinesesubstr($str, $start, $len) { // $str指字符串,$start指字符串的起始位置，$len指字符串长度
        $strlen = $start + $len; // 用$strlen存储字符串的总长度，即从字符串的起始位置到字符串的总长度
 $tmpstr="";
        for($i = $start; $i < $strlen;) {
            if (ord ( substr ( $str, $i, 1 ) ) > 0xa0) { // 如果字符串中首个字节的ASCII序数值大于0xa0,则表示汉字
                $tmpstr .= substr ( $str, $i, 3 ); // 每次取出三位字符赋给变量$tmpstr，即等于一个汉字
                $i=$i+3; // 变量自加3
            } else{
                $tmpstr .= substr ( $str, $i, 1 ); // 如果不是汉字，则每次取出一位字符赋给变量$tmpstr
                $i++;
            }
        }
        return $tmpstr; // 返回字符串
    }

include_once '../check1.php';
?>
<html>
<head>
<meta charset="utf-8" />
<title><?=gv($info_copy,"title");?>管理中心</title>
<link rel="stylesheet" href="/static/css/backend.css?0829" />
<link href="images/index_style.css" rel="stylesheet" type="text/css">
<link rel="stylesheet" href="/static/css/index_style.css" />
<script src="http://libs.baidu.com/jquery/1.8.3/jquery.min.js"></script></head>
<body>
<!--head-->
<div class="head">
	<div class="head_con">
          <span class="logo">
            <a href="#"><img src="images/logo.jpg" height="67" width="389"> </a>
          </span>
          <span class="title">
            <img src="images/title.jpg" height="78" width="215"> 
          </span>
     </div>
     <div class="head_bottom_bg"></div>
</div>
<!--head END-->
<!--MAIN START-->
<div class="main index_main">
     <div class="left">
          <div class="left_t">
               <img src="images/left_img.png"><br>
               <a href="/user/main.php">用户中心首页</a>
          </div>
          <ul>
             <li>
                <a href="/user/item.php" class="cpjwa1_select">
                 产品及文案
                </a>
             </li>
             <li>
                <a href="/user/order.php" class="cpjwa2">
                 订单与结算
                </a>
             </li>
             <li>
                <a href="/user/invite.php" class="cpjwa3">
                 邀请与奖励
                </a>
             </li>
             <li>
                <a href="/user/channelList.php" class="cpjwa4">
                 我的公众账号
                </a>
             </li>
             <li>
                <a href="/user/user_detail.php" class="cpjwa5">
                 我的信息
                </a>
             </li>
             <li>
                <a href="/user/terms.php" class="cpjwa7">
                 服务条款
                </a>
             </li>
              <li>
                <a href="../control.php?oper=loginout" class="cpjwa6">
                 退出登录
                </a>
             </li>
          </ul>
     </div>
	<div id="main" class="right ming_right">
	
	<div class="right_con">
            商品列表
        </div>
          <div class="right_con1">
              <a href="/user/main.php">返回用户首页</a>
          </div>
 	  <div class="cpjwa_con1">
            <ul>
     		<?php 
				$res=sql("s", "product", "*", " order by order1 desc");
				$suk='';
				$k=1;
				foreach ($res as $info){
					$jg=explode("-|-", gv($info,"jg"));
					$fc=explode("-|-", gv($info,"fc"));
					
						$suk="<i class='cpjwa_con1_c1'>价格<br>".$jg[1]."</i><i class='cpjwa_con1_c2'>返利<br>".$fc[1]."</i>";
					if($k%2==1){
								$col="#FFFFFF";
								}else{
									$col="#FFFFCC";
									}
					echo '<li><div class="cpjwa_con1_a"><a href="product.php?id='.gv($info,"id").'"><img src="../uploade/'.gv($info,"sptu").'" width="248" height="165"></a></div><div class="cpjwa_con1_b"><h2><a href="product.php?id='.gv($info,"id").'">'.gv($info,"name").'</a></h2><p class="cpjwa_con1_b_1"><i class="blue">推广说明：</i>'.chinesesubstr(gv($info,"tgsm"),0,131).'</p></div><div class="cpjwa_con1_c">'.$suk.'<a href="product.php?id='.gv($info,"id").'" class="cpjwa_con1_c3"><img src="../static/css/cp_img4.jpg" width="111" height="44"></a></div></li>';
					$k++;
				}
				?>
 </ul></div>
		
	<div class="uc-pager"></div>
 </div>

</div>
<!--foot-->
<?php include("../footer.html"); ?> 
<!--在线客服-->
<div class="fixedBox">
  <UL class="fixedBoxList">
    <LI style="display: block;" id="cartboxs" class="fixeBoxLi cart_bd">
      <P class="good_cart">0</P>
      <span class="fixeBoxSpan"></span> <strong>投诉意见</strong>
      <div class="cartBox">
        <div class="bjfff"></div>
        <div class="contactManager_box contactManager" id="cm_more">
  <!--[if IE 6]>
  <iframe src="about:blank" frameborder="0"></iframe>
  <![endif]-->
  <table>
    <tr class="contactManager_title">
      <td>
        <img src="../tp/3/images/icon_manager.jpg" alt="微分销" />
        <span>微分销</span>
      </td>
    </tr>

      <tr>
          <td>
             <a href="http://wpa.qq.com/msgrd?v=3&uin=<?=gv($home,"qq")?>&site=qq&menu=yes" target="_blank" alt="点击这里给我发消息" title="点击这里给我发消息">
          <img src="../tp/3/images/icon_qq.jpg" alt="QQ" />
          <span><?=gv($home,"qq")?></span>
        </a>
          </td>
      </tr>
    <tr>
      <td>
        <img src="../tp/3/images/icon_mobile.jpg" alt="手机号码" />
        <span><?=gv($home,"tel")?></span>
      </td>
    </tr>
    
    <tr>
      <td>
      <a title="交流群" >
        <img src="../tp/3/images/icon_qq.jpg" alt="群" />
        <span>QQ群：<?=gv($home,"qun")?></span>
      </a>
      </td>
    </tr>
  </table>

        </div>
      </div>
    </LI>
    <LI class="fixeBoxLi Home"> <A href="../index.html"> <span class="fixeBoxSpan"></span> <strong>返回首页</strong> </A> </LI>
    <LI class="fixeBoxLi BackToTop"> <span class="fixeBoxSpan"></span> <strong>返回顶部</strong> </LI>
  </UL>
</div>

<div style="display:none;">
			<!--放置客服代码-->
</div>

<script src="images/lanrenzhijia.js"></script>

<script src="/static/js/j.js?0829"></script>
</body>
</html><script>$(document).ready(function(){
ph('search');
});</script>